﻿$(".left .language a").click(function () {
    var language = $(this).data("value");

    var editor = ace.edit("editor1");
    editor.getSession().setMode("ace/mode/" + language);
    saveToStore("language1", language);
});

$(".right .language a").click(function () {
    var language = $(this).data("value");

    var editor = ace.edit("editor2");
    editor.getSession().setMode("ace/mode/" + language);
    saveToStore("language2", language);
});
